home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 March / PCWMAR09.iso / Software / FromTheMag / Ultimate Boot CD 3.22 / UBCD4WinV322.exe / {app} / oem1 / GeoShell / files / SetResGeo.cmd < prev   
Encoding:
Text File  |  2006-08-27  |  1.6 KB  |  56 lines

  1. @echo off
  2. setlocal
  3. TITLE Resolution...
  4. REM GeoShell Resolution CMD File
  5. REM Created by Benjamin Burrows 6/21/05
  6. REM edited by cdob 7/2/06: setres v2.1
  7. REM http://www.ubcd4win.com
  8.  
  9. REM SETRES v2.1 (c) Ian Sharpe April 2005. www.iansharpe.com
  10.  
  11. if [%1]==[] (echo no resolution requested & pause & goto :eof)
  12.  
  13. set temp_res=%temp%.\setres.txt
  14.  
  15. if [%1]==[-type-error] goto :type_error
  16.  
  17. set resolution=h%1
  18. if not [%2]==[] set resolution=%resolution% v%2
  19. if not [%3]==[] set resolution=%resolution% b%3
  20. if not [%4]==[] set resolution=%resolution% f%4
  21.  
  22.  
  23. echo setres.exe n %resolution% > %temp_res%
  24. %systemdrive%\Programs\Nu2Menu\setres.exe n %resolution% >> %temp_res%
  25.  
  26. rem Display mode changed?
  27. rem Show error in a new task to be recogniced by user.
  28. if ERRORLEVEL 1 (
  29.   start "Error" "%~0" -type-error
  30.   endlocal & exit
  31. )
  32.  
  33. rem Display mode is changed, adjust GeoShell
  34. set GeoTasksWidth=
  35. if (%1)==(640)  set GeoTasksWidth=340
  36. if (%1)==(800)  set GeoTasksWidth=500
  37. if (%1)==(1024) set GeoTasksWidth=710
  38. if (%1)==(1152) set GeoTasksWidth=900
  39. if (%1)==(1280) set GeoTasksWidth=1150
  40.  
  41. if not [%GeoTasksWidth%]==[] (
  42.   REG ADD "HKCU\Software\Geo\GeoShell\Plugins\GeoTasks0_1" /v "Plugin Width Hint" /t REG_DWORD /d "%GeoTasksWidth%" /f
  43.   %SystemDrive%\programs\geoshell\geoshell -quick_recycle
  44.   if exist %systemdrive%\Programs\myinfo\myinfo.exe %systemdrive%\Programs\myinfo\myinfo.exe
  45. )
  46.  
  47. if exist %temp_res% del %temp_res%
  48. endlocal & exit
  49.  
  50.  
  51. :type_error
  52. color 1E
  53. title Error: Display mode change failed
  54. type %temp_res% & del %temp_res%
  55. pause >nul
  56. endlocal & exit